package HTMLCrators;

import java.io.IOException;
import java.util.LinkedList;

import Main.Pair;

//just for test!!!!!
public class CreatorPrinter {
	
	public static void print(HTMLCreator creator){
		creator.init();
		while(creator.haveMoreLines()){
			System.out.println(creator.nextLine());
		}
		creator.finish();
	}

	public static void main1(String[] args) {
		System.out.println("start");
		LinkedList<Pair<String, String>> a1=new LinkedList<Pair<String,String>>();
		a1.add(new Pair<String, String>("a1","AAA"));
		a1.add(new Pair<String, String>("a2","BBB"));
		try {
			print(new HTMLCreatorFromFileAndPairs("justForTest.txt",a1));
		} catch (IOException e) {
			System.out.println("file Not Found");
		}
		System.out.println("end");
	}
	
	public static void main2(String[] args) {
		System.out.println("start");
		try {
			print(new HTMLCreatorFromFile("justForTest.txt"));
		} catch (IOException e) {
			System.out.println("file Not Found");
		}
		System.out.println("end");
	}
}
